<div class="address">
    <div class="nav">
        <div class="nav-li focus">收货地址</div>
    </div>

    <hr />

    <div class="add_address">
        <div class="text">
            <div class="addr">
                <select class="province" name="province" event-change={{ '$Event.province'}}>
                    <option class="first" value="0">请选择省</option>
                    {{#each city_list}}
                    <option rel="{{region_id}}" value="{{region_name}}">
                        {{region_name}}
                    </option>
                    {{/each}}
                </select>

                <select class="city" name="city" disabled event-change={{ '$Event.city'}}>
                    <option class="first" value="0">请选择市</option>
                </select>

                <select class="county" name="area" disabled>
                    <option class="first" value="0">请选择地区</option>
                </select>
                <input type="text" class="detailed_addre" name="detailed_addre" placeholder="详细地址" maxlength="25" />
            </div>

            <div class="connect">
                <input type="text" name="name" class="name" placeholder="收货人" maxlength="12" />
                <input type="text" name="mobile_num" class="mobile_num" placeholder="联系手机" maxlength="11" />
                <input type="text" name="phone_num" class="phone_num" placeholder="座机号码" maxlength="11" />
                <!-- <input type="text" name="zip_code" class="zip_code" placeholder="邮编" maxlength="6" /> -->
            </div>
            <button event-click="{{'$Event.add_user_address'}}" name="add_btn">添加地址</button>
        </div>

    </div>

    <div class="addrs">
        <table>
            <thead>
                <td class="name">收货人</td>
                <td class="area">所在地区</td>
                <td class="details">详细地址</td>
                <td class="phone_num">手机</td>
                <td class="default"></td>
                <td class="method">操作</td>
            </thead>
            {{#each user.address_detail}}
            <tr>
                <td class="name">{{name}}</td>
                <td class="area">
                    <span>{{province+","+town+","+county}}</span>
                </td>
                <td class="details">{{detail}}</td>
                <!-- <td class="zip_code">{{postcode}}</td> -->
                <td class="phone_num">{{mobilenumber}} {{phonenumber&&("/"+phonenumber)}}</td>
                <td class="default">
                    {{#if $Top.loginer.default_ua_id===_id}}
                    <p>默认地址</p>
                    {{#else}}
                    <button event-click="{{'$Top.$Event.user.set_default_address'}}">
                        设为默认地址
                    </button>
                    {{/if}}
                </td>
                <td class="method">
                    <!-- <input type="button" name="change" value="修改" /> -->
                    <button event-click="{{'$Top.$Event.user.remove_address'}}">删除</button>
                </td>
            </tr>
            {{/each}}
        </table>
    </div>
</div>
<script>
</script>
